home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c
- Path: bear.wn.bawue.de!jo
- From: jo@bear.wn.bawue.de (Joerg Sommrey)
- Subject: void ** question
- Message-ID: <DoJBrL.F5t@bear.wn.bawue.de>
- Organization: private
- Date: Tue, 19 Mar 1996 21:59:44 GMT
-
- Hi all,
-
- I have a question concerning conversion to `void **'. Given this piece
- of code:
-
- void f(void **);
- int main(void)
- {
- int **ppi;
- f(ppi);
- return 0;
- }
-
- On four platforms I get three results: silence, warning and error when
- calling f().
-
- The FAQ states there isn't a portable way of calling a function with a
- generic pointer by reference. This seems to be the point but I do not
- understand why.
-
- My questions:
- 1) Is `(void **) ppi' legal (which makes any tested compiler shut up)?
- If it is legal:
- 2) Why doesn't this conversion take place silently when calling f()?
-
- 3) Are any of these compilers broken?
-
- Thanks!
-
- -Jo
- --
- -rw-r--r-- 1 jo users 75 Mar 19 21:05 /home/jo/.signature
-